﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Views/Shared/Site.Master" Inherits="System.Web.Mvc.ViewPage<IEnumerable<SistemaDeBastanteodePoderes.Dominio.Usuario>>" %>

<asp:Content ID="Content1" ContentPlaceHolderID="TitleContent" runat="server">
	Index
</asp:Content>

<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">

    <h2>LISTA DE USUARIOS</h2>

    <table>
        <tr>
            <th></th>
            <th>Codigo</th>
            <th>Nombre</th>
            <th>Rol</th>
           
        </tr>

    <% foreach (var item in Model) { %>
    
        <tr>
            <td>
<%--                <%: Html.ActionLink("Editar", "Edit", new { Codigo=item.Codigo }) %> |
                <%: Html.ActionLink("Detalles", "Details", new { Codigo = item.Codigo })%> |
                <%: Html.ActionLink("Eliminar", "Delete", new { Codigo = item.Codigo })%>--%>
            </td>
            <td>
                <%: item.Codigo %>
            </td>
            <td>
                <%: item.Nombre %>
            </td>
            <td>
                <%: item.Rol.Descripcion %>
            </td>
        </tr>
    
    <% } %>

    </table>

    <p>
        <%: Html.ActionLink("Nuevo Usuario", "Create")%>
    </p>
    

</asp:Content>

